import React, { Component } from 'react';
import { Text, View,StyleSheet,TouchableNativeFeedback,Dimensions } from 'react-native';
import FadeInView from './FadeInView'


const stack = [1,2,3,4,5,6,7,8,9];
export default class Board extends Component {

	constructor(props) {
		super(props);
		this.state = { 
		
		};
	}
	click(){
		console.warn("123")
	}
	render() {
		
		return(
			<View style={styles.container}>				
				{
					stack.map((item,index) => {
						return (
							<View key={index+1} style={styles.warp}>
								{
									stack.map((item,index) => {
										return  <FadeInView key={index+1}>
													<TouchableNativeFeedback onPress={this.click.bind(this)}>													
														<View style={styles.btn}>
															<Text>{index}</Text>
														</View>													
													</TouchableNativeFeedback>
												</FadeInView>									
									})
								}
							</View>
						)
					})
				}					        
	        </View>
		);
	}
}
const styles = StyleSheet.create({
	container: {
		flexDirection:"row",
	},	
	warp:{
		flex:1,
	},
	btn:{	
		alignItems:'center',	
		justifyContent:'center',	
		borderRightWidth:1,
		borderBottomWidth:1,
		borderStyle:'solid',
		borderColor:'white',
		height:(Dimensions.get('window').width-60)/9-1,
		
	},
	
});